// Menu.h provides the attributes of the Menu class
//-----------------

#if !defined( MenuH)
#define MenuH

//-----------------
// Includes various libraries and files
#include <cassert>		// for asserts
#include <d3dx9.h>		// Direct 3D library (for all Direct 3D functions)

#include "Button.h"
#include "Cursor.h"
#include "Text.h"
#include "UserInterface.h"
//-----------------

// maximum number of buttons permitted in one menu
const int MAX_OPTIONS( 25);

class Menu {
	public:
		// constructors and destructor
		Menu();
		Menu( UserInterface* p_ui);
		virtual ~Menu();

		// accessors
		int get_text_length( const int& i) const;
		int get_number_of_buttons() const;
		bool mouseover( Cursor& mouse, const int& h) const;
		int get_button( const Cursor& mouse, const int& h) const;
		void render() const;
		void render( const int& i) const;
		void render( const int& i, int& text_length) const;

		// mutators
		void set_information( UserInterface* p_ui);
		void create_button( const std::string& t, const int& x, const int& y, const int& a, const int& r, const int& g, const int& b);
		void reset_buttons();

	private:
		UserInterface* p_ui_;

		Button options_[MAX_OPTIONS];
		int number_of_buttons_;
};

#endif